package com.aggron.util;

/**
 * 树的层级util
 * @author  liuhuan on 2018/6/2.
 */
public class LevelUtil {
    public static final String SEPARATOR=".";
    public static final String ROOT="0";

    public static String calculateLevel(String parentLevel,int parentId){
        if(StringUtils.isEmpty(parentLevel)){
            return ROOT;
        }else{
            return parentLevel+SEPARATOR+parentId;
        }
    }
}
